//
//  SoundSelectedViewController.m
//  拖小延闹钟
//
//  Created by rimi on 15/10/12.
//  Copyright (c) 2015年 Liukai. All rights reserved.
//

#import "SoundSelectedViewController.h"

@interface SoundSelectedViewController ()

@end

@implementation SoundSelectedViewController

- (void)viewDidLoad {
    [self initInterface];
    [super viewDidLoad];
    self.view.backgroundColor = [UIColor whiteColor];

}

- (void)initInterface {
    UIView *navBarView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, CGRectGetWidth(self.view.bounds), 64)];
    navBarView.backgroundColor = [UIColor colorWithWhite:0.900 alpha:1.000];
    //title
    UILabel *titleLabel = [[UILabel alloc] initWithFrame:CGRectMake(CGRectGetWidth(self.view.bounds) / 2 - 40, 20, 120, 40)];
    titleLabel.text = @"设定铃声";
    titleLabel.font = [UIFont systemFontOfSize:22];
    //personalButton
    UIButton *personalButton = [UIButton buttonWithType:UIButtonTypeCustom];
    personalButton.frame = CGRectMake(10, 20, 40, 40);
    [personalButton setImage:[UIImage imageNamed:@"后退"] forState:UIControlStateNormal];
    [personalButton addTarget:self action:@selector(backToLast:) forControlEvents:UIControlEventTouchUpInside];
    [navBarView addSubview:personalButton];
    [navBarView addSubview:titleLabel];
    [self.view addSubview:navBarView];
}

- (void)backToLast:(UIButton *)sender {
    [self.navigationController popViewControllerAnimated:YES];
}
/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
